﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

namespace Wicresoft.SelfService.WFInterface
{
    [DataContract]
    public class ActionResult
    {
        /// <summary>
        /// invoke ErrorMsg.
        /// if no error ErrorMsg == null
        /// else ErrorMsg == Exception.ToString()
        /// </summary>
        [DataMember]
        public string ErrorMsg { get; set; }

        /// <summary>
        /// return as current workflow step,should be same as db define:
        /// local_interface
        /// local_director
        /// remote_interface
        /// remote_director
        /// event_process
        /// </summary>
        [DataMember]
        public string Step { get; set; }

        /// <summary>
        /// return as workflow status:
        /// Pending -- pending for approve
        /// Rejected -- be rejected by approver
        /// Canceled -- be canceled by submitter
        /// Waiting -- enter in incident process
        /// </summary>
        [DataMember]
        public string Status { get; set; }

        /// <summary>
        /// reqeust code,unique guid for preventing duplicate request.
        /// </summary>
        [DataMember]
        public string RequestCode { get; set; }
    }
}
